import http from '@/utils/http';

// 查询当前用户操作设备的所有植物
export function getEnv(params) {
    // return http.get('/heng/query?dname=' + params);
    return http.get('/heng/queryenvplantname', {
        params: params
    });
}

// 实时数据接口
export const getNowData = (nowdata) => {
    return http.get('/heng/queryold', {
        nowdata: nowdata
    });
};

// 历史数据接口
export const getHistoryData = (historydata) => {
    return http.get('/heng/queryhistory?dname=' + historydata);
};